package com.checkoutcheckins.client.data;

import java.util.Comparator;

import com.checkoutcheckins.client.data.foursquare.Checkin;

public class CheckinDateDescCompare implements Comparator<Checkin>{

	@Override
	public int compare(Checkin o1, Checkin o2) {
		
		if (o1.getCreatedDate().getTime() == o2.getCreatedDate().getTime())
		{
			return 0;
		}
		else if (o1.getCreatedDate().getTime() > o2.getCreatedDate().getTime())
		{
			return -1;
		}
		else
		{
			return 1;
		}
	}

}
